var xmlhttp;
if (window.XMLHttpRequest){
    //IE7+,Fire,Chrome,Opera,Safari
    xmlhttp = new XMLHttpRequest();

}
else {
    xmlhttp =new  ActiveXObject("Micosoft.XMLHTTP");
}
xmlhttp.onreadystatechange =function () {
    if(xmlhttp.readyState ===4 &&xmlhttp.status===200) {

        //news_content.innerHTML = xmlhttp.responseText;
        showJson(JSON.parse(xmlhttp.responseText));

    }
}
//HTTP访问方法
xmlhttp.open("GET","date/news.json",true);
xmlhttp.send();
function showJson (jsonDate) {

    var temHtml ="";
    for (var i =0;i<10;i++){
        temHtml +="<li>";
        temHtml +="<a href=\""+jsonDate.list[i].news_url+"\">"+jsonDate.list[i].title+"</a>";
        temHtml +="<span class=\"time\">"+jsonDate.list[i].publish_time+"</span>";
        temHtml +="</li>\n";

    }
    document.getElementById("news_update_list").innerHTML=temHtml;

}